// client.h
#ifndef CLIENT_H
#define CLIENT_H

#include <QObject>
#include <QTcpSocket>
#include <QDateTime>
#include <QDebug>

class Client : public QObject
{
    Q_OBJECT
public:
    explicit Client(QObject *parent = nullptr);
    void connectToServer(const QString &host, quint16 port);

signals:

public slots:
    void onConnected();
    void onDisconnected();
    void onReadyRead();
    void sendMessage(const QString &message);
    void disconnectFromServer();

private:
    QTcpSocket *socket;
};

#endif // CLIENT_H
